package cn.lzj.basic.util;

import lombok.Data;

/**
 *  ajax请求的返回对象,封装
 */
@Data
public class AjaxResult{
    private Boolean success=true;
    private String message="操作成功!!!";

    public static  AjaxResult util(){
        return new AjaxResult();
    }
    /**
     *链式编程思想
     * @param success
     * @return
     */
    public AjaxResult setsuccess(Boolean success){
        this.success=success;
        return this;
    }
    public AjaxResult setmessage(String message){
        this.message=message;
        return this;
    }

}
